#define _CRT_SECURE_NO_WARNINGS 
#include"Stack.h"

void Stack::Init(int n = 4)
{
	_a = (int*)malloc(sizeof(int) * n);
	if (_a == nullptr)
	{
		perror("malloc fail");
		exit(1);
	}
	_capacity = n;
	_top = 0;

}